package kr.hkit.powerjava.chapter14.windowbuilder;

import java.awt.GridLayout;
import java.awt.HeadlessException;

import javax.swing.JButton;
import javax.swing.JFrame;




public class GridLayoutex2 extends JFrame {

	public GridLayoutex2() throws HeadlessException {
		setTitle("GridLayoutTest");
		setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
		
		setLayout(new GridLayout(0,3));
		
		add(new JButton("Button1"));
		add(new JButton("Button2"));
		add(new JButton("Button3"));
		add(new JButton("B4"));
		add(new JButton("Long Button5"));
		
		pack();
		setVisible(true);
	}

	
	
	
}

public class GridLayout2{
	public static void main(String[] args) {
		
	}
}